<template>
  <div class="home-banner">
      <!-- 轮播图组件 -->
    <XtxSlider :data="slidersData" />
  </div>
</template>

<script>
import { useBanner } from '@/hooks/page'
export default {
  name: 'HomeBanner',
  setup () {
    // const slidersData = ref([
    //   {
    //     hrefUrl: '/#/',
    //     id: '630000201807155635',
    //     imgUrl: 'http://zhoushugang.gitee.io/erabbit-client-pc-static/images/b1.jpg'
    //   },
    //   {
    //     hrefUrl: '/#/',
    //     id: '650000201207058528',
    //     imgUrl: 'http://zhoushugang.gitee.io/erabbit-client-pc-static/images/b2.jpg'
    //   }
    // ])
    const { slidersData } = useBanner()

    return { slidersData }
  }
}
</script>

<style scoped lang='less'>
.home-banner {
  width: 1240px;
  height: 500px;
  position: absolute;
  left: 0;
  top: 0;
  z-index: 98;
}
</style>
